//
//  AddressModel.m
//  wtshoppingcite
//
//  Created by TW on 14-11-19.
//  Copyright (c) 2014年 TW. All rights reserved.
//

//

#import "AddressModel.h"

@implementation AddressModel

- (id)initWithAddressInfo:(NSDictionary *)info{
    if(self = [super init]){
        id area = [info objectForKey:@"area"];
        self.area = ObjToString(area);
        
        id city = [info objectForKey:@"city"];
        self.city = ObjToString(city);
        
        id name = [info objectForKey:@"consignee"];
        self.name = ObjToString(name);
        
        id defaultAddr = [info objectForKey:@"defaultAddr"];
        self.defaultAddr = ObjToString(defaultAddr);
        
        id postcode = [info objectForKey:@"postcode"];
        self.code = ObjToString(postcode);
        
        id province = [info objectForKey:@"province"];
        self.province = ObjToString(province);
        
        id shipId = [info objectForKey:@"shipId"];
        self.shipId = ObjToString(shipId);
        
        id specificAddr = [info objectForKey:@"specificAddr"];
        self.address = ObjToString(specificAddr);
        
        
        id tel = [info objectForKey:@"tel"];
        self.phone = ObjToString(tel);
    }
    return self;
}
@end
